var dataUrl = "http://120.78.160.58/wxJavaPlat/";
function JsonToFormdata(param){
    var data=new FormData();
    for(var key in param){
        var value= param[key];
        data.append(key,value);
    }
    return data;
}
function fetchPostJson(url,param,success,fail){
    fetch(dataUrl+url,{
        method:'POST',
        body:JsonToFormdata(param),
        }).then(response => response.json())
        .then(json => {
           success(json);
        })
        .catch(function(error) {
           alert(dataUrl+url);
        })
}
